package com.woniuxy01;

/**
 * @author 作者
 * @create 2025-09-08 11:12
 */
public class Test03 {
    public static void main(String[] args) {
        //买了一台电脑
        Computer computer = new Computer();
        UsbDisc usbDisc = new UsbDisc();
        computer.setUsb(usbDisc);
        computer.getUsb().work();

        UsbMouse usbMouse = new UsbMouse();
        computer.setUsb(usbMouse);
        computer.getUsb().work();
    }
}
